1. Field of the Invention
The present invention relates to a device for controlling a robot. The present invention also relates to a method for controlling a robot.
2. Description of the Related Art
An industrial robot (hereinafter referred to simply as a robot) operates so as to follow a certain operation program (or a task program). When several kinds of operation programs are prepared, which correspond to the types of tools (or end effecters) attached to the robot, the types of objective workpieces, the contents of tasks, etc., and are suitably and selectively given to a robot, the robot as a single machine can execute various kinds of tasks. In order to prepare an operation program to control the operation of a robot, an operator makes the respective control axes of the robot run in a manual mode at low speed, generally by using an operating panel or “a teach pendant”, so as to sequentially position a tool at a plurality of working points at which a task is performed on a workpiece, and thereby makes the robot store the working points as “taught points”. The robot stores the actual positions of the respective control axes at an instant the tool is positioned at each of the working points, as the information of position and orientation of the robot at each of the taught points. In this connection, it is also known to perform the above programming by teaching, through an offline simulation using a personal computer or the like.
The robot can repeatedly perform the identical task to follow the taught operation program. If it is required to change the contents of the task, a new operation program matching the new task contents must be prepared. For example, in a case where an item to be produced is added or changed in a highly automated manufacturing system using a robot, a production line is required to be modified. In this connection, a large number of actions are required to redesign various kinds of hardware, such as a jig, a machine, a conveyor, etc., and to prepare or remake various kinds of software, such as a processing program of a processing machine, an operation program of a robot, a sequence ladder and a production management program of a programmable controller (PC) or a production management device, etc. Effectively reducing the number of actions required to construct the hardware/software, so as to deal with a modification of the production line, has been recognized as a significant problem relating to costs in the automated manufacturing system, and therefore it is desirable to decrease the number of steps for preparing an operation program of a robot.
As a measure for facilitating the preparation and/or change of the operation program of a robot, it has been known that a single cycle task, performed by a robot for a single workpiece, is divided into a plurality of mutually different units of works (or work units), and a plurality of operation programs commanding the respective work units are prepared and then given to the robot in a suitably combined form. For example, Japanese Unexamined Patent Publication (Kokai) No. 2004-185228 (JP-A-2004-185228) discloses a configuration in which, in a manufacturing cell including a robot and a processing machine, a series of tasks performed by the robot and processing machine are divided into several work units, and an information processing device gives several operation programs, for commanding the respective work units, to the robot or the processing machine in a suitable order. When it is desired to add or change a produced item, it is sufficient to review or remake an operation program in relation only to a work unit required to be added or changed in company with the addition or change of the produced item, which can reduce the cost for preparing or remaking the robot operation program in company with the change in the production line.
In this connection, the term “a work unit” in the present application means a task that can be specified or distinguished on the basis of a single action, such as holding a workpiece, placing a workpiece, watching a workpiece, and so on. Usually, it is not reasonable, during a period when one work unit is performed, to insert a different work unit therein. Upon combining several identical or different work units with each other in various ways, various kinds of tasks can be realized.
In a manufacturing system for manufacturing a plurality of products in a parallel or synchronous manner, when, for example, a single robot operates to feed workpieces into, and take out workpieces from, a plurality of processing machines, it is generally difficult to realize feeding/taking-out tasks for several workpieces subjected to different processing particulars (i.e., different production cycles) together in one series of operation programs. Usually, a feeding and taking-out task for a workpiece relative to a single processing machine is realized by a robot operation program for a single work unit, and operation programs, each for a single work unit, are prepared so as to match the respective processing machines. Then, in accordance with a command from an upper controller, the robot performs the feeding and taking-out task for a workpiece relative to each processing machine as commanded. In this connection, until an operation program for one processing machine is completed, the robot does not start an operation program for another processing machine. According to this configuration, even if a process, such as an air blowing or an axis moving in a processing machine, which tends to take a relatively long time, is to be performed between a workpiece feeding step and a workpiece taking-out step, the robot simply waits for the finish of this process.
According to a configuration such that, as described in JP-A-2004-185228, a single cycle task is divided into several work units that in turn are instructed to a robot and a processing machine, it is possible to perform feeding and taking-out tasks for workpieces relative to respective processing machines in a parallel manner, for each work unit representing a certain task (e.g., a feeding) common to the processing machines. However, in this configuration, the robot performs a subsequent work unit only after completing one work unit, so that, in a case where time (e.g., a processing time) required to perform a common work unit is different for the respective workpieces, a cycle time of the feeding and taking-out tasks for workpieces relative to all processing machines is dominated by a workpiece involving a time-consuming work unit. In other words, it is difficult, in this configuration, to effectively reduce the waiting time of the robot and thus to efficiently perform the tasks, while comprehending the operating state of the manufacturing system as occasion demands.
On the other hand, in a case where a manufacturing system stops in an emergency due to a machine trouble or the like, an operator sometimes intervenes manually in the system by, e.g., manually removing a workpiece from a jig, manually switching on/off a signal, manually transferring a robot to a retreated position, so as to check or eliminate the cause of the emergency stop. When the operator manually intervenes in the operation of the manufacturing system, the state of the manufacturing system alters from the state at the instant of the emergency stop and thus loses a correlation with the operation program of the robot, so that the task cannot be restarted as it is. Therefore, a certain recovery work is necessarily performed, such that the state of the manufacturing system is manually altered so as to match the particulars of the operation program at the restarting thereof, or the robot is artificially operated by certain steps so as to allow the interrupted operation program to be matched with the state of the manufacturing system. In order to properly perform this recovery work, the operator is required to well understand the configuration of the equipment of the manufacturing system and/or the contents of the operation programs executed by the respective machines.